﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web;
namespace BLL
{
    public class WebPageBase : System.Web.UI.Page
    {
        protected override void OnInit(EventArgs e)
        {
            if (Session["s2username"] == null)
                if (SecurityServices.CheckCookieOnClient())
                    SecurityServices.SetCurrentUser(SecurityServices.GetUserNameFromCookie());
                else
                    Response.Redirect("login.aspx?RetUrl=" + Request.Url.PathAndQuery + "");
            base.OnInit(e);
        }
    }
}
